1. Field of the Invention
The present invention relates to elimination of noise in a video signal encoder and more particularly to a method and apparatus for eliminating noise in a video signal encoder, which computes energy of a noise component and a pure signal component and controls a variable gain over a filtering path based upon energy content of the noise component with respect to whole signal components.
2. Description of Related Art
Noise elimination performed in a conventional video signal encoder, for example, a moving picture experts group (MPEG)2 video signal encoder, depends on gain control which is represented with xe2x80x9c1xe2x88x92axe2x80x9d as shown in FIG. 1 over a path of a signal.
FIG. 1 shows a video signal encoder employing a conventional noise elimination method. The encoder comprises: subtracter 101 for extracting an error signal from an input video signal which is processed in the unit of blocks; gain variable part 102 for performing a gain control operation of xe2x80x9c1xe2x88x92axe2x80x9d (xe2x80x9caxe2x80x9d is a gain) with respect to an output signal of the subtracter 101; gain control part 103 for controlling a gain of the gain variable part 102; discrete cosine transform (DCT)/quantization (Q) part 104 for performing DCT and quantization with respect to an output signal of the gain variable part 102; inverse quantization (IQ)/inverse DCT (IDCT) part 105 for performing inverse quantization and inverse DCT with respect to the discrete cosine transformed and quantized signal; adder 106 for summing the inverse discrete cosine transformed signal and a motion compensated signal; memory 107 for storing the summed signal; and motion estimation and compensation part 108 for performing motion estimation and motion compensation using an output signal of the memory 107 and an input video signal.
Referring to FIG. 1 having such configuration, an input signal, g(i,j,k), (xe2x80x9ci,jxe2x80x9d is a two dimensional coordinate of a video processing unit on a frame and xe2x80x9ckxe2x80x9d is time domain information corresponding to the xe2x80x9ci,jxe2x80x9d in a time frame) is a combination of noise (n(i,j,k)) and pure signal (f(i,j,k)).
Accordingly, a pixel, f(ixe2x88x92dx,jxe2x88x92dy,kxe2x88x921), in a previous frame is subtracted from a current frame pixel, g(i,j,k), so as to calculate a difference between the current frame pixel and the previous frame pixel. A gain value, a, is controlled based upon the difference. Noise is eliminated in such a manner of reducing the noise by increasing the gain, a, when the difference between the current frame pixel and the previous frame pixel is smaller than a predefined threshold.
Specifically, once receiving the input signal, g(i,j,k), the subtracter 101 subtracts a pixel, f(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921), corresponding to the input signal, g(i,j,k), (the pixel has been predicted by the motion estimation and compensation part 108) from the input signal, and the subtractor 101 outputs a result of the subtraction to respective the gain variable part 102 and the gain control part 103. The gain control part 103 increases or decreases the gain, a, of the gain variable part 102 according to the output of the subtractor 101, that is, the scale of the difference between the two frames, thus reducing the noise.
For example, as shown in FIG. 2, the subtracter 101 calculates a difference between an input signal and a predicted signal as follows: d(i,j,k)=g(i,j,k)xe2x88x92f(ixe2x88x92dx,jxe2x88x92dx, kxe2x88x921)=f(i,j,k)xe2x88x92f(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921)+n(i,j,k). If the motion estimation and compensation is exact, the difference signal, d(i,j,k), is mainly composed of noise, n(i,j,k), so the gain control part 103 adjusts the gain, a, of the gain variable part 102 to on the order of xe2x80x981xe2x80x99, thus eliminating all of the d(i,j,k). On the other hand, if the motion estimation and compensation is not exact, the d(i,j,k) may be detected to be mainly composed of a signal component, f(i,j,k)xe2x88x92f(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921), so the gain control part 103 adjusts the gain, a, to on the order of xe2x80x980xe2x80x99, thus not eliminating the d(i,j,k) even though it may not eliminate the noise component, n(i,j,k).
In other words, as illustrated in FIG. 2, the gain control part 103 performs an absolute operation with respect to the difference signal between the input signal and the motion compensated signal, and compares an average of the result values to a reference value, thus controlling increase and decrease of the gain, a, of the gain variable part 102 according to the scale of a difference between the two values.
The gain control is performed only in an INTER mode. In an INTRA mode, the gain control process is bypassed. For this operation, a switching part which switches according to the INTER/INTRA mode is coupled to a front end of the DCT/Q part 104.
In the INTRA mode, a macroblock is encoded using only information on its own macroblock, so the motion estimation is not performed. On the other hand, in the INTER mode, the macroblock is encoded using information on another macroblock at another time as well as its own macroblock, so the motion estimation is performed.
A signal where the gain, a, has been controlled and noise has been reduced is input to the DCT/Q part 104. The signal is converted into frequency information through DCT and quantization by the DCT/Q part 104. The quantized signal is sent to output part 109 for transmission and, simultaneously, sent to the IQ/IDCT part 105. The IQ/IDCT part 105 performs dequantization and IDCT of the quantized signal and then sends a result signal to the adder 106. The adder adds the inverse discrete transformed signal to the motion compensated signal from the motion estimation and compensation part 108 so as to reconstruct an original signal. The reconstructed original signal is stored in the memory 107.
The signal stored in the memory 107 is input to the motion estimation and compensation part 108. The motion estimation and compensation part 108 performs motion estimation and compensation with respect to a current frame based upon the signal stored in the memory 107 and then sends the result to the respective subtracter 101 and adder 106.
The output part 109 performs variable length coding (VLC) and first input first output (FIFO) with respect to the noise eliminated and quantized signal and then the result signal is output in the form of a bit stream.
Such video signal encoder to which the conventional noise elimination method is applied uses a scale of the sum of the difference signals as a reference for determining how many signal components, f(i,j,k)xe2x88x92f(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921), are contained in the difference signal, d(i,j,k).
Since the signal components and noise components are all together contained in the sum of the difference signals without discrimination, it cannot be identified which of the signal and noise is larger, so the system cannot properly manage the case that the noise components are much more than the signal components or the opposite case. Additionally, unnecessary filtering, such as elimination of a video signal as well as the noise, may be performed, decreasing efficiency in the noise elimination.
The conventional video signal encoder performs noise filtering in the INTER mode, so there occurs problem that the noise does not eliminated over a path where the filtering is not performed. Since the conventional video signal encoder uses only one previous pixel, the noise is not completely eliminated, and, moreover, blocking effect may increase.
FIGS. 3(a) to 3(d) illustrate the blocking effect.
Since the motion estimation and compensation is performed with respect to original image in the unit of blocks, as shown in FIG. 3(a), discontinuities 201 may occur at block boundaries in predicted image.
Since the gain control (1xe2x88x92a) for mc error image(the error signal is indicative of a difference between an input signal including noise and a predicted signal as shown in FIG. 3(b)), distorts block boundary of the mc error image during the noise reduction ,as shown in FIG. 3(c), discontinuities 202 occur at block boundaries between neighboring blocks in filtered image as shown in FIG. 3(d). This results to deterioration in picture quality due to the blocking effect at the block boundaries.
As illustrated, in the conventional noise elimination method and the conventional video signal encoder employing the conventional method, the noise elimination is in close relation with the operation of the motion estimation and compensation part.
Namely, to effectively eliminate the noise, displacement, (dx,dy), satisfying f(i,j,k)=f(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921) should be exactly found with respect to each pixel so that g(i,j,k)xe2x88x92g(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921)=n(i,j,k)xe2x88x92n(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921) can be realized.
Since the MPEG2 video signal encoder finds the displacement, (dx,dy), in the unit of blocks, however, detection of exact displacement of each pixel cannot be guaranteed. Therefore, g(i,j,k)xe2x88x92g(ixe2x88x92dx,jxe2x88x92dx,kxe2x88x921) may include considerable amount of signal components as well as noise components and the image where the noise is filtered through the gain control of xe2x80x9c1xe2x88x92axe2x80x9d may necessarily include discontinuities at block boundaries, thus causing blocking effect and deterioration in picture quality and reducing even pure signal.
Accordingly, the present invention is directed to a method and apparatus for eliminating noise in a video signal encoder that substantially obviates one or more of the limitations and disadvantages of the related art.
An objective of the present invention is to provide a method for eliminating noise in a video signal encoder, for dividing a video signal to be filtered into noise components and pure signal components and calculating energy of the respective noise and pure signal so as to variable-control a gain over a filtering path according to a rate of the energy of the noise and pure signal, thereby improving noise elimination performance.
Another objective of the present invention is to provide a method and apparatus for eliminating noise in a video signal encoder, for preserving as many signal components as can be judged as pure signal components in an input signal containing noise and controlling the remaining signal components of the input signal using a gain over a gain control path, thus preventing blocking effect and eliminating the noise.
Further another objective of the present invention is to provide a method and apparatus for eliminating noise in a video signal encoder, which uses a signal-adaptive weight while extracting pure signal components, thereby effectively eliminating noise even if rapid signal change occurs when considering correlation between a pixel where noise will be eliminated and its adjacent pixels.
Additional features and advantages of the invention will be set forth in the following description, and in part will be apparent from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention will be realized and attained by the structure as illustrated in the written description and claims hereof, as well as the appended drawings.
To achieve these and other advantages, and in accordance with the purpose of the present invention as embodied and broadly described, a method for eliminating noise in a video signal encoder comprises the steps of: dividing the input video signal into a noise component and a pure signal component; calculating energy of the respective noise component and pure signal component; and variable-controlling a gain over a filtering path according to a rate of the calculated energy.
The step of dividing the input video signal comprises the step of filtering a difference between the input video signal and the motion compensated signal and dividing the noise component from the pure signal component.
The step of dividing the input video signal comprises the step of calculating an average of the input video signal in the unit of blocks and dividing the noise component from the pure signal component.
The step of dividing the input video signal comprises the step of performing low pass filtering with respect to each pixel and dividing the noise component from the pure signal component.
The step of dividing the input video signal comprises the step of performing an adaptive filtering with the coefficients corresponding to local pixel-correlation from a pixel to be filtered and dividing the noise component from the pure signal component.
In another embodiment of the present invention, a method for eliminating noise in a video signal encoder comprises: the error signal extracting step of computing a difference signal between a current input video signal containing noise and a previous video signal where noise has been eliminated; the signal extracting step of extracting a pure signal component without the noise from the error signal; the noise reducing step of reducing the noise through variable gain control according to the energy-ratio between the error signal and said extracted pure signal component; and the resolution recovering step of adding the extracted signal to the noise reduced signal component so as to recover resolution which has been deteriorated during noise filtering.
In another aspect of the present invention, an apparatus for eliminating noise in a video signal encoder comprises: an error signal detecting part for computing a difference signal between a current input video signal containing noise and a previous video signal where noise has been eliminated; a signal preserving part for extracting a pure signal component without the noise from the error signal; a gain control part for calculating a gain from an energy ratio between the error signal and the extracted pure signal component; a gain variable part for eliminating the noise through variable gain control according to the gain from the gain control part; and an adder for summing the signal component where the noise has been eliminated by the gain variable means and the pure signal component extracted by the signal preserving part.
In another aspect of the present invention, a method for eliminating noise in a video signal encoder comprises the steps of: extracting a pure signal component without noise from a current input video signal containing the noise and a previous video signal where the noise has been eliminated; performing variable gain control with respect to the respective input video signal and extracted signal; and performing noise filtering using a difference value between the previous video signal and a sum of the extracted video signal and the variable gain controlled signal.
In another aspect of the present invention, an apparatus for eliminating noise in a video signal encoder comprises: an error signal detecting part for computing, as an error signal, a difference between a current input video signal containing noise and a previous video signal where the noise has been eliminated; a signal preserving part for extracting a pure signal component without noise from the error signal; a gain control part for variable-controlling a gain according to the energy-ratio calculated from the error signal and the extracted pure signal; a first gain variable part for controlling the extracted signal component of the signal preserving part according to the gain which is varied by the gain control part; a second gain variable part for controlling the input video signal component according to the gain which is varied by the gain control part; an adder for summing output values of the respective first and second gain variable part; and a subtracter for calculating a difference between an output value of the adder and the motion estimation/motion compensation part.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory and are intended to provide further explanation of the invention as claimed.